<?php

namespace common\models;

use Yii;

/**
 * This is the model class for table "banner".
 *
 * @property string $id ID
 * @property string $image 图片
 * @property string $link 跳转链接
 * @property int $created_at 创建时间
 */
class Banner extends \yii\db\ActiveRecord
{
    /**
     * {@inheritdoc}
     */
    public static function tableName()
    {
        return 'banner';
    }

    /**
     * {@inheritdoc}
     */
    public function rules()
    {
        return [
            [['created_at'], 'integer'],
            [['image', 'link'], 'required'],
        ];
    }

    /**
     * {@inheritdoc}
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'image' => '图片',
            'link' => '跳转链接',
            'created_at' => '创建时间',
        ];
    }
}
